package com.nowcoder.community.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;

import java.util.Date;

@Data
public class Comment {

    /**
     * 自增主键,插入数据后将自增主键设置到对象中
     */
    @TableId(type = IdType.AUTO)
    private Integer id;
    private Integer userId;
    /**
     * 评论的类型,可能是帖子,也可能是评论
     */
    private Integer entityType;

    /**
     * 具体的目标id
     */
    private Integer entityId;

    /**
     * 记录被回复的目标id
     */
    private Integer targetId;
    private String content;
    private Integer status;
    private Date createTime;
}
